<h2>
      <span id="vote_score">
        Score: <%= @story.votes.count %>
      </span>
  <%= @story.name %>
 </h2>
 <ul id="vote_history">
    <% if @story.votes.size.zero? %>
      <em>No shoves yet!</em>
    <% else %>
      <ul>
      <%= render :partial => 'vote', :collection => @story.latest_votes%>
      </ul>
    <% end %>
 </ul>
<p>
    <%= @story.description %>
</p>
 <p class="submitted_by">
   Submitted by: 
   <span><%= link_to @story.user.login, :controller => 'account', 
    :action => 'show', :id => @story.user.login %>
</span>
 </p>
<p><%= link_to @story.link, @story.link %></p>
<p>
    <% if @story.tags.size.nonzero? %>
      <p class="tags">
        <strong>Tags:</strong>
        <%= render :partial => 'tag', :collection => @story.tags %>
      </p>
    <% end %>
</p>
<% if logged_in? %>
<div id="vote_link">
  <%= link_to_remote 'shove it', {:url => { :action => 'vote', :id => @story }}, { :href => url_for( :action => 'vote', :id => @story)}%>
</div>
<% else %>
  <p>
    <em>
      You would be able to vote for this story and add comments if you were 
      <%= link_to 'logged in', :controller => 'account', :action => 'login'%>
      </em>
    </p>
<% end %>


  <% if @story.comments_count > 0 %>
    <h3>There are <%= @story.comments_count %> comments</h3>
        <div id="comments">
            <%= render :partial => 'comment', :collection => @story.comments %>
        </div>
  <% else %>
    <h3>No comments yet!</h3>
  <% end %>

<% if logged_in? %>
  <div id="comment_form">
  <% form_remote_tag :url => {:action => 'add_comment', :id => @story } do %>
    <p>Comment:<br /><%= text_area_tag 'comment' %></p>
    <%= submit_tag 'Post'%>
  <% end %>
  </div>
<% end %>
